<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body>
<table cellspacing="0" border="0" width="995">
	<tr>
		<td width="995" class="title_manager_product">Quản lý hỗ trợ trực tuyến</td>
	</tr>
	<tr>
		<td height="90">
			<table border="0" cellpadding="0" cellspacing="0" width="995">
				<tr>
					<td align="center">
						<table border="0" cellpadding="0" cellspacing="0">
							<tr>
								<td align="center"><a href="index.php?admin=supportAdmin&do=formaddsupportcategory"><img src="images/CreateNews.gif" width="48" height="47" border="0" /></a></td>
							</tr>
							<tr>
								<td align="center" class="title_new_add"><a href="index.php?admin=supportAdmin&do=formaddsupportcategory">Tạo danh mục hỗ trợ</a></td>
							</tr>
						</table>
						
					</td>
				</tr>
			</table>
		</td>	
	</tr>
</table>

<table class="reference" cellspacing="0" border="0" width="995">
	<tr>
		<td width="995">
			<form action="index.php?admin=supportAdmin&do=formaddsupportcategory" method="post">
				<table cellspacing="0" border="0" width="995">
					<tr>
						
						<td width="790" class="title_manager_cate">Tạo danh mục hỗ trợ trực tuyến</td>
					
					</tr>
				</table>
				<table class="reference" cellspacing="0" border="1" width="995"> 
					<tr>
						<td colspan="2" align="center">
							<?php
								$idyahoo = $_POST['idyahoo'];
								$namesupport = $_POST['namesupport'];
								if(isset($_POST['submit'])){
									if($idyahoo==''){
										echo "<font color=\"red\">Bạn phải nhập vào id yahoo.</font>";
									}else{
										$query="INSERT INTO productdownloadcategories(idyahoo,namesupport) VALUES ('$idyahoo','$namesupport')";
										mysql_query($query);
										echo "Thêm danh mục hỗ trợ thành công.";
										echo "<script>window.location='index.php?admin=supportAdmin&do=listsupport'</script>";	
									}
								}	
							?>	
						</td>
					</tr>	
					<tr>
						<td width="300"><b>ID Yahoo:</b></td>
						<td width="400">
							<input type="text" name="idyahoo" size="40" /><font color="#FF0000"> * </font>
						</td>
					</tr>
					<tr>
						<td width="300"><b>Tên người hỗ trợ:</b></td>
						<td width="400">
							<input type="text" name="namesupport" size="40" />
						</td>
					</tr>
				  
				   <tr>
						<td></td>
						<td>
							<input type="submit" name="submit" value="Tạo hỗ trợ mới" />
							<input type="reset" name="reset" value="Nhập lại" />
							<input type="button" name="Cancel" value="Cancel" onclick="window.location = 'index.php?admin=supportAdmin&do=listsupport' " />
						<td>
				   </tr>
				</table>
			</form>
		</td>
	</tr>	
</table>
</body>
</html>